home *** CD-ROM | disk | FTP | other *** search
- /*
- PAR CREATE ANIM FROM IMAGES
- By J.L. White
- ©1994 Merlin's Software
-
- Takes Multiple Images & Builds PAR Anim File
- Personal Animation Recorder Script
- Requires The Rexxarplib.library
- Use As The Last Script In Multiple Script Mode
-
- Batch Factory Batch Conversion Scripts are basically Arexx scripts that
- allow you to pass certain parameters to the external program you wish
- to use to convert the images from one format to another. You can pass
- five different strings from Batch Factory to the script by using the
- following commands:
-
- $N = This will pass the current selected filename.
- $P = This will tell Batch Factory to ask for a path to save new frames to.
- $# = This will pass the current frame number in the script.
- $T = This will pass the total number of frames in the script.
- $A = This will pass an offset number to be used to save frames with.
-
- NOTE: The following line is required to work as a Batch Factory Script:
-
- PARSE=$N $# $T
-
- */
-
- arg InFile FileNum TotalNum
- options results
- if ~show('l', "rexxarplib.library") then do
- check = addlib('rexxsupport.library',0,-30,0)
- check = addlib('rexxarplib.library',0,-30,0)
- end
- PName = "Batch"
-
-
- Top = 170
- Height = ScreenRows(PName)
- if Height < 400 then Top = 70
- call Locate_PAR
- address "DDR"
-
-
- if FileNum = 1 then do
- address "AREXX" ScreenToFront(PName)
- call Request(200,Top," Enter Q-Factor (1-23)","8","OKAY","CANCEL",PName)
- if result < 1 then result = 1
- QFactor result
- call Request(200,Top,"Enter Block Limit (1-220)","156","OKAY","CANCEL",PName)
- if result < 1 then result = 156
- Limit result
- Filter On
- Mode Anim
- call Request(200,Top,"Enter Name For Project!","","OKAY","CANCEL",PName)
- if result = "" then do
- call Request(200,Top-14,"Process Has Been Cancelled\Please Abort Script!!",,"OK",,PName)
- address command "Wait 3"
- exit
- end
- Path = result
- call Request(200,Top,"Enter Name For Animation!","","OKAY","CANCEL",PName)
- if result = "" then do
- call Request(200,Top-14,"Process Has Been Cancelled\Please Abort Script!!",,"OK",,PName)
- address command "Wait 3"
- exit
- end
- Name = left(result,17)
- Name = strip(Name)
- call open OutData,"RAM:PAFI.Temp",'W'
- call writeln OutData,Path
- call writeln OutData,Name
- call close OutData
- address command "Makedir DDR:"Path
- end
- else do
- call open InData,"RAM:PAFI.Temp",'R'
- Path = readln(InData)
- Name = readln(InData)
- call close InData
- Path = strip(Path)
- Name = strip(Name)
- end
-
- address command "Copy "InFile" To DDR:"Path"/"Name
- if FileNum = TotalNum then do
- DONE
- address command "C:Delete >NIL: RAM:PAFI.Temp"
- end
- exit
-
- Locate_PAR:
- if (POS('DDR',SHOW('Ports')) = 0)
- then do
- call Request(180,Top-14,"Can Not Locate The PAR Software\Please Abort Script & Try Again!",,"OK",,PName)
- address command "Wait 3"
- end
- return
-
-
-
-